package com.authine.cloudpivot.ext.enums.inquiry;

/**
 * Created by continue on 2017/12/21.
 */
public enum InquiryStatusEnum {


    /**
     * 询价商品状态
     */
    INQUIRY_GOODS_0_NEW("0", "新建"),

    INQUIRY_GOODS_1_APPROVE("1", "审核中"),

    INQUIRY_GOODS_2_APPROVE_NO("2", "已退回"),

    INQUIRY_GOODS_3_QUOTING("3", "报价中"),

    INQUIRY_GOODS_4_END("4", "已结束"),

    INQUIRY_GOODS_5_CLOSE("5", "已关闭");


    private final String code;
    private final String des;

    private InquiryStatusEnum(String code, String des) {
        this.code = code;
        this.des = des;
    }

    public String getCode() {
        return code;
    }

    public String getDes() {
        return des;
    }

    public static InquiryStatusEnum get(String code) {
        for (InquiryStatusEnum c : InquiryStatusEnum.values()) {
            if (c.code.equals(code)) {
                return c;
            }
        }
        return null;
    }
}
